class ModelEntity {
  String? info;
  String? logo;
  String? name;
  OpenView? openView;
  String? page;
  String? price;
  String? priceOld;
  String? sales;
  String? tag;
  int? type;
  bool? upgrade;

  ModelEntity(
      {this.info,
        this.logo,
        this.name,
        this.openView,
        this.page,
        this.price,
        this.priceOld,
        this.sales,
        this.tag,
        this.type,
        this.upgrade});

  ModelEntity.fromJson(Map<String, dynamic> json) {
    info = json['info'];
    logo = json['logo'];
    name = json['name'];
    openView = json['openView'] != null
        ? new OpenView.fromJson(json['openView'])
        : null;
    page = json['page'];
    price = json['price'];
    priceOld = json['priceOld'];
    sales = json['sales'];
    tag = json['tag'];
    type = json['type'];
    upgrade = json['upgrade'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['info'] = this.info;
    data['logo'] = this.logo;
    data['name'] = this.name;
    if (this.openView != null) {
      data['openView'] = this.openView!.toJson();
    }
    data['page'] = this.page;
    data['price'] = this.price;
    data['priceOld'] = this.priceOld;
    data['sales'] = this.sales;
    data['tag'] = this.tag;
    data['type'] = this.type;
    data['upgrade'] = this.upgrade;
    return data;
  }
}

class OpenView {
  String? endTime;
  int? isOpen;

  OpenView({this.endTime, this.isOpen});

  OpenView.fromJson(Map<String, dynamic> json) {
    endTime = json['endTime'];
    isOpen = json['isOpen'];
  }

  Map<String, dynamic> toJson() {
    final Map<String, dynamic> data = new Map<String, dynamic>();
    data['endTime'] = this.endTime;
    data['isOpen'] = this.isOpen;
    return data;
  }
}